package utilities
{
	import org.flixel.*;
	
	/**
	 * ...
	 * @author JAC
	 */
	public class Emitter extends FlxEmitter
	{
		public function Emitter(X:Number = 0, Y:Number = 0, Size:Number = 0):void
		{
			super(X, Y, Size);
		}
		
		public function createParticles(width:uint = 2, height:uint = 2, color:uint = 0xFFFFFFFF):void
		{
			for (var i:int = 0; i < maxSize / 2; i++)
			{
				var particle:FlxParticle = new FlxParticle();
				particle.makeGraphic(width, height, color);
				particle.visible = false;
				add(particle);
				
				particle = new FlxParticle();
				var randSize:uint = (width - 1) * FlxG.random() + 1;
				particle.makeGraphic(randSize, randSize, color);
				particle.visible = false;
				add(particle);
			}
		}
	}
}